package com.irdstudio.apicenter.console.service.authenticate;

import java.sql.SQLException;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.irdstudio.apicenter.console.dm.AppwxRespDetail;
import com.irdstudio.apicenter.console.dm.AppwxRespDetailDao;

@Service(value = "appwxRespDetailService")
public class AppwxRespDetailService {

	@Autowired
	private AppwxRespDetailDao appwxRespDetailDao;

	public int insertOne(AppwxRespDetail appwxRespDetail) throws SQLException,
			ClassNotFoundException {
		return appwxRespDetailDao.save(appwxRespDetail);
	}

	public AppwxRespDetail queryAppTradePrivate(String recordKey, int wx_resp_rank) throws SQLException {
		return appwxRespDetailDao.queryWithKeys(recordKey, wx_resp_rank);
	}

	public int update(AppwxRespDetail appwxRespDetail) throws SQLException,
			ClassNotFoundException {
		return appwxRespDetailDao.update(appwxRespDetail);
	}

	public int delete(String recordKey, int wx_resp_rank) throws SQLException,
			ClassNotFoundException {
		return appwxRespDetailDao.delete(recordKey, wx_resp_rank);
	}

}